<?php

class TestController extends Model3_Scaffold_Controller
{
    public function __construct($request)
    {
        $this->_sc = new Scaffold_DefaultDb_User();
        parent::__construct($request);
    }
    
    public function indexAction()
    {
        
    }

    public function addAction()
    {
        // para encriptar la contraseña en MD5
        if($this->getRequest()->isPost())
        {
            $this->_post = $this->getRequest()->getPost();
            if(isset($this->_post['password']) && $this->_post['password'] != '')
            {
                $this->_post['password'] = md5($this->_post['password']);
            }
        }

        parent::addAction();
    }
}